package com.financing.platform.service.impl;

import java.sql.SQLException;
import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

import com.financing.platform.dao.IForegroundProductDao;
import com.financing.platform.dto.ForegroundProductDTO;
import com.financing.platform.service.IForegroundProductService;

@Repository("foregroundProductService")
public class ForegroundProductServiceImpl implements IForegroundProductService {
	@Autowired
	private IForegroundProductDao foregroundProductDao;

	@Override
	public int addForegroundProduct(ForegroundProductDTO foregroundProductDto) throws SQLException {
		return foregroundProductDao.addForegroundProduct(foregroundProductDto);
	}

	@Override
	public List<ForegroundProductDTO> queryForegroundProduct(
			ForegroundProductDTO foregroundProductDto) throws SQLException {
		return foregroundProductDao.queryForegroundProduct(foregroundProductDto);
	}

	@Override
	public int editForegroundProduct(ForegroundProductDTO foregroundProductDto)
			throws SQLException {
		return foregroundProductDao.editForegroundProduct(foregroundProductDto);
	}

	@Override
	public Integer countForegroundProduct(ForegroundProductDTO foregroundProductDto)
			throws SQLException {
		return foregroundProductDao.countForegroundProduct(foregroundProductDto);
	}

	@Override
	public List<ForegroundProductDTO> queryForegroundProductBySendEmail(
			String pids) throws SQLException {
		return foregroundProductDao.queryForegroundProductBySendEmail(pids);
	}

	@Override
	public Map<String,Object> queryForegroundProductDetail(
			ForegroundProductDTO foregroundProductDto) throws SQLException {
		return foregroundProductDao.queryForegroundProductDetail(foregroundProductDto);
	}

	

	
}
